package com.howard.core;

import org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSource;

/**
 * 动态数据源配置 支持主从 读写分离
 *
 * @author <a href="mailto:howard.he0329@gmail.com">Howard.He</a>
 *
 */
public class DynamicDataSource extends AbstractRoutingDataSource {

	@Override
	protected Object determineCurrentLookupKey() {
		return DataSourceManager.getDataSourceName();
	}
}
